using Google.ProtocolBuffers;
using micromsg.Proto;
using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.IO;
using System.Runtime.CompilerServices;
namespace micromsg
{
	[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
	public sealed class BindCookie : GeneratedMessageLite<BindCookie, BindCookie.Builder>
	{
		[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
		public sealed class Builder : GeneratedBuilderLite<BindCookie, BindCookie.Builder>
		{
			private bool resultIsReadOnly;
			private BindCookie result;
			protected override BindCookie.Builder ThisBuilder
			{
				get
				{
					return this;
				}
			}
			public override bool IsInitialized
			{
				get
				{
					return this.result.IsInitialized;
				}
			}
			protected override BindCookie MessageBeingBuilt
			{
				get
				{
					return this.PrepareBuilder();
				}
			}
			public override BindCookie DefaultInstanceForType
			{
				get
				{
					return BindCookie.DefaultInstance;
				}
			}
			public string Mobile
			{
				get
				{
					return this.result.Mobile;
				}
				set
				{
					this.SetMobile(value);
				}
			}
			public string Verifycode
			{
				get
				{
					return this.result.Verifycode;
				}
				set
				{
					this.SetVerifycode(value);
				}
			}
			public uint Expire
			{
				get
				{
					return this.result.Expire;
				}
				set
				{
					this.SetExpire(value);
				}
			}
			public Builder()
			{
				this.result = BindCookie.DefaultInstance;
				this.resultIsReadOnly = true;
			}
			internal Builder(BindCookie cloneFrom)
			{
				this.result = cloneFrom;
				this.resultIsReadOnly = true;
			}
			private BindCookie PrepareBuilder()
			{
				if (this.resultIsReadOnly)
				{
					BindCookie other = this.result;
					this.result = new BindCookie();
					this.resultIsReadOnly = false;
					this.MergeFrom(other);
				}
				return this.result;
			}
			public override BindCookie.Builder Clear()
			{
				this.result = BindCookie.DefaultInstance;
				this.resultIsReadOnly = true;
				return this;
			}
			public override BindCookie.Builder Clone()
			{
				if (this.resultIsReadOnly)
				{
					return new BindCookie.Builder(this.result);
				}
				return new BindCookie.Builder().MergeFrom(this.result);
			}
			public override BindCookie BuildPartial()
			{
				if (this.resultIsReadOnly)
				{
					return this.result;
				}
				this.resultIsReadOnly = true;
				return this.result.MakeReadOnly();
			}
			public override BindCookie.Builder MergeFrom(IMessageLite other)
			{
				if (other is BindCookie)
				{
					return this.MergeFrom((BindCookie)other);
				}
				base.MergeFrom(other);
				return this;
			}
			public override BindCookie.Builder MergeFrom(BindCookie other)
			{
				return this;
			}
			public override BindCookie.Builder MergeFrom(ICodedInputStream input)
			{
				return this.MergeFrom(input, ExtensionRegistry.Empty);
			}
			public override BindCookie.Builder MergeFrom(ICodedInputStream input, ExtensionRegistry extensionRegistry)
			{
				this.PrepareBuilder();
				uint num;
				string text;
				while (input.ReadTag(out num, out text))
				{
					if (num == 0u && text != null)
					{
						int num2 = Array.BinarySearch<string>(BindCookie._bindCookieFieldNames, text, StringComparer.get_Ordinal());
						if (num2 < 0)
						{
							this.ParseUnknownField(input, extensionRegistry, num, text);
							continue;
						}
						num = BindCookie._bindCookieFieldTags[num2];
					}
					uint num3 = num;
					if (num3 <= 10u)
					{
						if (num3 == 0u)
						{
							throw InvalidProtocolBufferException.InvalidTag();
						}
						if (num3 == 10u)
						{
							this.result.hasMobile = input.ReadString(ref this.result.mobile_);
							continue;
						}
					}
					else
					{
						if (num3 == 18u)
						{
							this.result.hasVerifycode = input.ReadString(ref this.result.verifycode_);
							continue;
						}
						if (num3 == 24u)
						{
							this.result.hasExpire = input.ReadUInt32(ref this.result.expire_);
							continue;
						}
					}
					if (WireFormat.IsEndGroupTag(num))
					{
						return this;
					}
					this.ParseUnknownField(input, extensionRegistry, num, text);
				}
				return this;
			}
			public BindCookie.Builder SetMobile(string value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasMobile = true;
				this.result.mobile_ = value;
				return this;
			}
			public BindCookie.Builder ClearMobile()
			{
				this.PrepareBuilder();
				this.result.hasMobile = false;
				this.result.mobile_ = "";
				return this;
			}
			public BindCookie.Builder SetVerifycode(string value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasVerifycode = true;
				this.result.verifycode_ = value;
				return this;
			}
			public BindCookie.Builder ClearVerifycode()
			{
				this.PrepareBuilder();
				this.result.hasVerifycode = false;
				this.result.verifycode_ = "";
				return this;
			}
			public BindCookie.Builder SetExpire(uint value)
			{
				this.PrepareBuilder();
				this.result.hasExpire = true;
				this.result.expire_ = value;
				return this;
			}
			public BindCookie.Builder ClearExpire()
			{
				this.PrepareBuilder();
				this.result.hasExpire = false;
				this.result.expire_ = 0u;
				return this;
			}
		}
		public const int MobileFieldNumber = 1;
		public const int VerifycodeFieldNumber = 2;
		public const int ExpireFieldNumber = 3;
		private static readonly BindCookie defaultInstance;
		private static readonly string[] _bindCookieFieldNames;
		private static readonly uint[] _bindCookieFieldTags;
		private bool hasMobile;
		private string mobile_ = "";
		private bool hasVerifycode;
		private string verifycode_ = "";
		private bool hasExpire;
		private uint expire_;
		private int memoizedSerializedSize = -1;
		public static BindCookie DefaultInstance
		{
			get
			{
				return BindCookie.defaultInstance;
			}
		}
		public override BindCookie DefaultInstanceForType
		{
			get
			{
				return BindCookie.DefaultInstance;
			}
		}
		protected override BindCookie ThisMessage
		{
			get
			{
				return this;
			}
		}
		public string Mobile
		{
			get
			{
				return this.mobile_;
			}
		}
		public string Verifycode
		{
			get
			{
				return this.verifycode_;
			}
		}
		public uint Expire
		{
			get
			{
				return this.expire_;
			}
		}
		public override bool IsInitialized
		{
			get
			{
				return this.hasExpire;
			}
		}
		public override int SerializedSize
		{
			get
			{
				int num = this.memoizedSerializedSize;
				if (num != -1)
				{
					return num;
				}
				num = 0;
				if (this.hasMobile)
				{
					num += CodedOutputStream.ComputeStringSize(1, this.Mobile);
				}
				if (this.hasVerifycode)
				{
					num += CodedOutputStream.ComputeStringSize(2, this.Verifycode);
				}
				if (this.hasExpire)
				{
					num += CodedOutputStream.ComputeUInt32Size(3, this.Expire);
				}
				this.memoizedSerializedSize = num;
				return num;
			}
		}
		private BindCookie()
		{
		}
		public override void WriteTo(ICodedOutputStream output)
		{
			int arg_06_0 = this.SerializedSize;
			string[] bindCookieFieldNames = BindCookie._bindCookieFieldNames;
			if (this.hasMobile)
			{
				output.WriteString(1, bindCookieFieldNames[1], this.Mobile);
			}
			if (this.hasVerifycode)
			{
				output.WriteString(2, bindCookieFieldNames[2], this.Verifycode);
			}
			if (this.hasExpire)
			{
				output.WriteUInt32(3, bindCookieFieldNames[0], this.Expire);
			}
		}
		public override int GetHashCode()
		{
			int num = base.GetType().GetHashCode();
			if (this.hasMobile)
			{
				num ^= this.mobile_.GetHashCode();
			}
			if (this.hasVerifycode)
			{
				num ^= this.verifycode_.GetHashCode();
			}
			if (this.hasExpire)
			{
				num ^= this.expire_.GetHashCode();
			}
			return num;
		}
		public override bool Equals(object object_0)
		{
			BindCookie bindCookie = object_0 as BindCookie;
			return bindCookie != null && (this.hasMobile == bindCookie.hasMobile && (!this.hasMobile || this.mobile_.Equals(bindCookie.mobile_))) && (this.hasVerifycode == bindCookie.hasVerifycode && (!this.hasVerifycode || this.verifycode_.Equals(bindCookie.verifycode_))) && (this.hasExpire == bindCookie.hasExpire && (!this.hasExpire || this.expire_.Equals(bindCookie.expire_)));
		}
		public override void PrintTo(TextWriter writer)
		{
			GeneratedMessageLite<BindCookie, BindCookie.Builder>.PrintField("mobile", this.hasMobile, this.mobile_, writer);
			GeneratedMessageLite<BindCookie, BindCookie.Builder>.PrintField("verifycode", this.hasVerifycode, this.verifycode_, writer);
			GeneratedMessageLite<BindCookie, BindCookie.Builder>.PrintField("expire", this.hasExpire, this.expire_, writer);
		}
		public static BindCookie ParseFrom(byte[] data)
		{
			return BindCookie.CreateBuilder().MergeFrom(data).BuildParsed();
		}
		private BindCookie MakeReadOnly()
		{
			return this;
		}
		public static BindCookie.Builder CreateBuilder()
		{
			return new BindCookie.Builder();
		}
		public override BindCookie.Builder ToBuilder()
		{
			return BindCookie.CreateBuilder(this);
		}
		public override BindCookie.Builder CreateBuilderForType()
		{
			return new BindCookie.Builder();
		}
		public static BindCookie.Builder CreateBuilder(BindCookie prototype)
		{
			return new BindCookie.Builder(prototype);
		}
		static BindCookie()
		{
			BindCookie.defaultInstance = new BindCookie().MakeReadOnly();
			BindCookie._bindCookieFieldNames = new string[]
			{
				"expire",
				"mobile",
				"verifycode"
			};
			BindCookie._bindCookieFieldTags = new uint[]
			{
				24u,
				10u,
				18u
			};
			object.ReferenceEquals(micromsg.Proto.BindCookie.Descriptor, null);
		}
	}
}
